#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
using namespace std;
int n;
string s;
char ans[1000][1000];

int main()
{
    cin >> n;
    getline(cin, s);
    //getchar();
    getline(cin, s);

    int k = 0;
    int dul = s.size() / n;
    for (int i = dul ; i >= 0; i--)
    {
        for (int j = 0; j < n; j++)
        {
            ans[j][i] = s[k++];
        }
    }
    for (int i = 0; i < n; i++)
    {
        for (int j = 0; j < dul+1; j++)
        {
            if (j == 0&&ans[i][j]=='\0'&&n!=1)
            {
                    cout << " ";
            }
            else

            cout << ans[i][j];
        }
        cout << endl;
    }
    return 0;
}
